#ifndef __Bullet_h_
#define __Bullet_h_

#include "Item.h"
#include "MovableItem.h"

class Weapon;

class Bullet : public Item, public MovableItem, public Ogre::FrameListener
{

	friend class Weapon;

	// Attributes ------------------------------------------------------------------------------
protected:
	Weapon* weapon;
	static int ID;
	static const char* DEFAULT_NAME;

public:
	static const char* DEFAULT_NODE_NAME;

	// Methods ---------------------------------------------------------------------------------
protected:
	Bullet(Weapon* _weapon, Ogre::Entity* entity, const Ogre::Vector3& position);
	virtual ~Bullet();
	virtual void initialize();

public:
	virtual bool move();
	virtual void collision(Item* _item);
	virtual void collisionWithBullet(Bullet* _bullet);
	virtual void collisionWithEnemy(Enemy* _enemy);
	virtual void collisionWithMainCharacter(MainCharacter* _mainCharacter);
	virtual void collisionWithFish(Fish* _fish);
	virtual void collisionWithBonus(Bonus* _bonus);
	virtual void collisionWithWeapon(Weapon* weapon);
	virtual bool frameStarted(const Ogre::FrameEvent& evt);
	Weapon* getWeapon() { return weapon; }
	//void reset(Weapon* _weapon, Ogre::Entity* entity, const Ogre::Vector3& position);
	void reset(const Ogre::Vector3& position);

};

#endif